package org.jsola.hr.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;
import org.jsola.core.dto.BaseDTO;

import static org.jsola.hr.example.AttendShiftExample.E_AFTER_WORK_NEED_PUNCH;
import static org.jsola.hr.example.AttendShiftExample.E_ATTEND_PLAN_ID;
import static org.jsola.hr.example.AttendShiftExample.E_EARLIEST_PUNCH_TIME;
import static org.jsola.hr.example.AttendShiftExample.E_EARLY_MINUTE;
import static org.jsola.hr.example.AttendShiftExample.E_IS_ADVANC;
import static org.jsola.hr.example.AttendShiftExample.E_IS_ALLOWED_LATE_EARLY;
import static org.jsola.hr.example.AttendShiftExample.E_IS_ALLOW_LATE_LATE;
import static org.jsola.hr.example.AttendShiftExample.E_LATEST_PUNCH_TIME;
import static org.jsola.hr.example.AttendShiftExample.E_LATE_MINUTE;
import static org.jsola.hr.example.AttendShiftExample.E_NAME;
import static org.jsola.hr.example.AttendShiftExample.E_OFF_WORK_LATE_MINUTE;
import static org.jsola.hr.example.AttendShiftExample.E_ON_WORK_LATE_MINUTE;
import static org.jsola.hr.example.AttendShiftExample.E_PERIOD_JSON;
import static org.jsola.hr.example.AttendShiftExample.M_ATTEND_PLAN_ID_MAX;
import static org.jsola.hr.example.AttendShiftExample.M_EARLIEST_PUNCH_TIME_MAX;
import static org.jsola.hr.example.AttendShiftExample.M_LATEST_PUNCH_TIME_MAX;
import static org.jsola.hr.example.AttendShiftExample.M_NAME_MAX;
import static org.jsola.hr.example.AttendShiftExample.M_PERIOD_JSON_MAX;
import static org.jsola.hr.example.AttendShiftExample.N_AFTER_WORK_NEED_PUNCH;
import static org.jsola.hr.example.AttendShiftExample.N_ATTEND_PLAN_ID;
import static org.jsola.hr.example.AttendShiftExample.N_EARLIEST_PUNCH_TIME;
import static org.jsola.hr.example.AttendShiftExample.N_EARLY_MINUTE;
import static org.jsola.hr.example.AttendShiftExample.N_IS_ADVANC;
import static org.jsola.hr.example.AttendShiftExample.N_IS_ALLOWED_LATE_EARLY;
import static org.jsola.hr.example.AttendShiftExample.N_IS_ALLOW_LATE_LATE;
import static org.jsola.hr.example.AttendShiftExample.N_LATEST_PUNCH_TIME;
import static org.jsola.hr.example.AttendShiftExample.N_LATE_MINUTE;
import static org.jsola.hr.example.AttendShiftExample.N_NAME;
import static org.jsola.hr.example.AttendShiftExample.N_OFF_WORK_LATE_MINUTE;
import static org.jsola.hr.example.AttendShiftExample.N_ON_WORK_LATE_MINUTE;
import static org.jsola.hr.example.AttendShiftExample.N_PERIOD_JSON;

/**
 * @author zhr
 */
@EqualsAndHashCode(callSuper = true)
@ApiModel(description = "新增【考勤班次】的参数")
@Data
public class AttendShiftAddDTO extends BaseDTO {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(notes = N_ATTEND_PLAN_ID, example = E_ATTEND_PLAN_ID)
    @Length(max = 32, message = M_ATTEND_PLAN_ID_MAX)
    private String attendPlanId;

    @ApiModelProperty(notes = N_NAME, example = E_NAME)
    @Length(max = 50, message = M_NAME_MAX)
    private String name;

    @ApiModelProperty(notes = N_PERIOD_JSON, example = E_PERIOD_JSON)
    @Length(max = 1000, message = M_PERIOD_JSON_MAX)
    private String periodJson;

    @ApiModelProperty(notes = N_IS_ADVANC, example = E_IS_ADVANC)
    private Boolean isAdvanc;

    @ApiModelProperty(notes = N_IS_ALLOWED_LATE_EARLY, example = E_IS_ALLOWED_LATE_EARLY)
    private Integer isAllowedLateEarly;

    @ApiModelProperty(notes = N_LATE_MINUTE, example = E_LATE_MINUTE)
    private Integer lateMinute;

    @ApiModelProperty(notes = N_EARLY_MINUTE, example = E_EARLY_MINUTE)
    private Integer earlyMinute;

    @ApiModelProperty(notes = N_IS_ALLOW_LATE_LATE, example = E_IS_ALLOW_LATE_LATE)
    private Integer isAllowLateLate;

    @ApiModelProperty(notes = N_OFF_WORK_LATE_MINUTE, example = E_OFF_WORK_LATE_MINUTE)
    private Integer offWorkLateMinute;

    @ApiModelProperty(notes = N_ON_WORK_LATE_MINUTE, example = E_ON_WORK_LATE_MINUTE)
    private Integer onWorkLateMinute;

    @ApiModelProperty(notes = N_EARLIEST_PUNCH_TIME, example = E_EARLIEST_PUNCH_TIME)
    @Length(max = 10, message = M_EARLIEST_PUNCH_TIME_MAX)
    private String earliestPunchTime;

    @ApiModelProperty(notes = N_LATEST_PUNCH_TIME, example = E_LATEST_PUNCH_TIME)
    @Length(max = 10, message = M_LATEST_PUNCH_TIME_MAX)
    private String latestPunchTime;

    @ApiModelProperty(notes = N_AFTER_WORK_NEED_PUNCH, example = E_AFTER_WORK_NEED_PUNCH)
    private Integer afterWorkNeedPunch;


}

